/*
 * @Description: 基础统计接口
 * @Author: Zzt
 * @Date: 2022-12-07 11:04:31
 * @LastEditTime: 2023-03-04 11:31:23
 */
import { statRequest } from '@/utils/request';
/* 统计档案类型数量 */
export function archiveCount() {
  return statRequest({
    url: `/fonds-archive-type/archive-type-count/`,
    method: 'get'
  });
}
/* 统计全宗数量 */
export function fondsCount() {
  return statRequest({
    url: `/fonds-archive-type/fonds-count/`,
    method: 'get'
  });
}
/* 统计管理用户和利用用户 */
export interface IUserTotalParams {
  unitId: Number | string;
}

export function userTotal(params: IUserTotalParams) {
  return statRequest({
    url: `/statUser/getUserTotal/`,
    method: 'get',
    params
  });
}
/* 获取磁盘容量 */
export function diskSize() {
  return statRequest({
    url: `/disk-size/`,
    method: 'get'
  });
}
/* 获取销毁档案数量 */
export function destroyNum() {
  return statRequest({
    url: `/archive-volume/destroy/`,
    method: 'get'
  });
}

/* 获取实际档案数量 */
export function realNum() {
  return statRequest({
    url: `/archive-volume/real-count/`,
    method: 'get'
  });
}
/* 获取入库档案数量 */
export function toDb() {
  return statRequest({
    url: `/archive-volume/to-db/`,
    method: 'get'
  });
}
/* 按全宗统计档案容量 */

export interface IVolumeByFondsParams {}
export function volumeByFonds(data: IVolumeByFondsParams) {
  return statRequest({
    url: `/archive-volume/volume-by-fonds/`,
    method: 'post',
    data
  });
}
/* 按全宗内-保管期限-统计电子档案数量接口 */
export interface IElectronicFileParams {
  // archiveTypeIds: any[];
  // fileFormatList: any[];
}
export function electronicFileTotal(data: IElectronicFileParams) {
  return statRequest({
    url: `/statBase/getElectronicFileTotal/`,
    method: 'post',
    data
  });
}
/* 按全宗内-密级-统计电子档案数量接口 */
export interface ISecretParams {
  // archiveTypeIds: any[];
  // fileFormatList: any[];
}
export function secretTotal(data: ISecretParams) {
  return statRequest({
    url: `/statBase/getSecretTotal/`,
    method: 'post',
    data
  });
}
